

{extend name="layout"}
{block name="detail"}
<header class="aui-header-default aui-header-fixed aui-header-bg">
    <a href="" class="aui-header-item" style="visibility:hidden;">
        <i class="aui-icon aui-icon-back-white"></i>
    </a>
    <div class="aui-header-center aui-header-center-clear">
        <div class="aui-header-center-logo">
            <div class="aui-car-white-Typeface">待退款</div>
        </div>
    </div>
    <a href="#" class="aui-header-item-icon" style="min-width:0;visibility:hidden;">
        <i class="aui-icon aui-icon-member"></i>
    </a>
</header>
<section class="aui-myOrder-content">
    <div class="m-tab demo-small-pitch" data-ydui-tab>
        <div class="aui-myOrder-fix">
            <ul class="tab-nav">
                <li class="tab-nav-item "><a href="{:url('index/center/saleWaitSend')}">待发货</a></li>
                <li class="tab-nav-item "><a href="{:url('index/center/saleWaitReceive')}">待收货</a></li>
                <li class="tab-nav-item " ><a href="{:url('index/center/saleSuccess')}">已完成</a></li>
                <li class="tab-nav-item tab-active" ><a href="{:url('index/center/saleWaitRefund')}">待退款</a></li>
                <li class="tab-nav-item "><a href="{:url('index/center/saleComment')}">商品评价</a></li>
            </ul>
        </div>
        <div class="tab-panel">
            <div class="tab-panel-item tab-active">
                <ul id="datas">
                    {volist name="data['orders']" id="order"}
                    <li>
                        <div class="aui-list-title-info">
                            <a href="#" class="aui-well ">
                                <div class="aui-well-bd">
                                    <img src="{$order.userImg}" style="width: 30px;border-radius:100% ;display:inline-block;margin-right: 10px;">
                                    <b>{$order.nickname}</b>
                                </div>
                                <div class="aui-well-ft">{$order.createTime|date="Y-m-d H:i:s",###}</div>
                            </a>
                            <a href="{:url('index/shop/product_dtl',['id'=>$order['productId'],'sid'=>$order['shopId']])}" class="aui-well ">
                                <div class="aui-well-bd">订单ID：{$order.payment_order_id}</div>
                                <div class="aui-well-ft">{$order_status[$order.status]}</div>
                            </a>
                            <a href="{:url('index/shop/product_dtl',['id'=>$order['productId'],'sid'=>$order['shopId']])}" class="aui-list-product-fl-item" style="padding:5px 10px;background:#eee;">
                                <div class="aui-list-product-fl-img" style="width:60px;background:#eee;padding:0px 5px;">
                                    <img src="{$order.productImg}">
                                </div>
                                <div class="aui-list-product-fl-text" style="background: #eee;">
                                    <h3 class="aui-list-product-fl-title" style="background: #eee;">{$order.title}</h3>
                                    <p class="aui-list-product-fl-title" style="background: #eee;text-align: right">规格{$order.guige} * {$order.num}</p>

                                </div>
                            </a>
                        </div>
                        <div style="text-align:right;padding-right:10px;margin-top:10px;">
                            <b>共{$order.num}件商品，实付金额￥{$order.totalFee/100}元</b>
                        </div>
                        <div class="aui-list-title-btn">
                        {if condition="$order.status2"}
                            <a href="{:url('index/center/refundDetail')}?id={$order.id}">退款详情</a>
                        {/if}
                        <!-- 最终货源所有者-->
                        {if condition="$order.productUid eq $uid"}
                        {if condition="$order.status eq 1 and ($order.status2 eq 0 or $order.status2 eq 7)"}
                            <a href="{:url('index/center/sendOrder')}?id={$order.id}">立即发货</a>
                        {/if}

                        {if condition="$order.status2 eq 6"}
                            <a href="{:url('index/center/changeRefund')}?id={$order.id}&rs=success">已收到退货，同意退款</a>
                            <a href="{:url('index/center/changeRefund')}?id={$order.id}&rs=reject" class="red-color">没有收到退货，拒绝退款</a>
                        {/if}
                        <!--                         已支付已发货，买家申请退款   -->
                        {if condition="$order.status2 eq 5 and $order.status eq 2"}
                        <!--仅退款-->
                            <a href="{:url('index/center/changeRefund')}?id={$order.id}&rs=success">同意退款</a>
                            <a href="{:url('index/center/changeRefund')}?id={$order.id}&rs=reject" class="red-color">拒绝退款</a>
                        {/if}

                        {if condition="$order.status2 eq 4 and $order.status eq 2"}
                        <!--仅退款退货-->
                            <a href="{:url('index/center/changeRefund')}?id={$order.id}&rs=agree">同意退货退款</a>
                            <a href="{:url('index/center/changeRefund')}?id={$order.id}&rs=reject" class="red-color">拒绝退货退款</a>
                        {/if}

                        {/if}

                        <!--                         已支付没发货，买家申请退款   -->
                        {if condition="$order.status2 eq 5 and $order.status eq 1"}
                        <!--仅退款-->
                            <a href="{:url('index/center/changeRefund')}?id={$order.id}&rs=success">同意退款</a>
                            <a href="{:url('index/center/changeRefund')}?id={$order.id}&rs=reject" class="red-color">拒绝退款</a>

                        {/if}

                        {if condition="$order.status2 eq 4 and $order.status eq 1"}
                        <!--仅退款退货-->
                            <a href="{:url('index/center/changeRefund')}?id={$order.id}&rs=agree">同意退货退款</a>
                            <a href="{:url('index/center/changeRefund')}?id={$order.id}&rs=reject" class="red-color">拒绝退货退款</a>
                        {/if}
                        </div>
                        <div class="aui-dri"></div>
                    </li>
                    {/volist}
                </ul>
            </div>
        </div>
    </div>
</section>
<div style="height:100px;"></div>

{/block}